#pragma once
#include <map>  
#include <set>
typedef std::map< std::pair<int,int>, double>::const_iterator clm_it;  
  
class Graph  
{  
  
private:  
    int nNodes;  
    int nEdges;

    bool isDirected;  
	std::map< std::pair<int,int>, double > link_map;  
	
	std::map< std::pair<int,int>, double > old_map; 
	int* id;
	int* xCoord;
	int* yCoord;
public:  
	Graph();
    Graph( const int& nodes, const bool& directed );  
    ~Graph();  
    void Graph::setIds(std::set<int>);
    int V() const;  
    int E() const;  
    bool directed() const;  
	void addEdge(int a, int b);
    void insert( const int& s, const int& t, const double& weight ); 
	void Graph::insert( const int& s, const int& t );
    void remove( const int& s, const int& t );  
    bool edge( const int& s, const int& t);  
	void Graph::createNewGraph(const int& nodes, const bool& directed );
    clm_it getEdge( const int& s, const int& t);      
    void show() const;  
	void draw(CPaintDC *dc) const;      
	int getId(CPoint point);
};  
